<?php
class Front_Model_Translate extends Administrator_Model_System{
	public function __construct() {
		$this->db = Zend_Registry::get ( 'vicdbsystem' );
		$this->lang = new Nguyen_language_system ();
	}
	//content
	public function ContentLink($id,$lang){
		return BASE_URL;
	}
	public function CatLink($id,$lang){
		return BASE_URL;
	}
	public function SectionLink($id,$lang){
		return BASE_URL;
	}
	//product
	public function ProdetailsLink($id,$lang){
		$model = new Administrator_Model_Product_View();
		$info = $model->GetProductInfo($id);
		$catinfo = $model->GetPro_catInfo($info['cat']);
		$typeinfo = $model->GetProduct_type($info['type']);
		$storeinfo = $model->GetProduct_type($info['store']);
		$stalias = $this->vn_str_filter($storeinfo['name']);
		$tpalias = $this->vn_str_filter($typeinfo['name']);
		$catalias = $this->vn_str_filter($catinfo['name']);
		$pralias = $this->vn_str_filter($info['name']);
		return BASE_URL.'/'.$stalias.'/'.$tpalias.'/'.$catalias.'/'.$pralias.'-'.$id.'.p.html';
	}
	public function ProCatLink($id,$lang){
		$model = new Administrator_Model_Product_View();
		$info = $model->GetPro_catInfo($id);
		$typeinfo = $model->GetProduct_type($info['type']);
		$storeinfo = $model->GetProduct_type($typeinfo['store']);
		$stalias = $this->vn_str_filter($storeinfo['name']);
		$tpalias = $this->vn_str_filter($typeinfo['name']);
		$catalias = $this->vn_str_filter($info['name']);
		return BASE_URL.'/'.$stalias.'/'.$tpalias.'/'.$catalias.'-'.$id.'.c.html';
	}
	public function ProTypeLink($id,$lang){
		$model = new Administrator_Model_Product_View();
		$info = $model->GetProduct_type($id);
		$storeinfo = $model->GetProduct_type($info['store']);
		$stalias = $this->vn_str_filter($storeinfo['name']);
		$tpalias = $this->vn_str_filter($info['name']);
		return BASE_URL.'/'.$stalias.'/'.$tpalias.'-'.$id.'.t.html';
	}
	public function ProStoreLink($id,$lang){
		return BASE_URL;
	}
	public function ProManufactLink($id,$lang){
		return BASE_URL;
	}
	public function ProTagLink($id,$lang){
		return BASE_URL;
	}
	
}